#include<iostream>
#include<stdio.h>

using namespace std;

#include <iomanip>
#include  <cmath>
#include <stdlib.h>
#include <string.h>

void init(int a[], int b) {
    int w;
    for (w = 0; w < b; w++) {
        a[w] = 0;
        cout << " " << a[w];
    }
}

void reverse(int a[], int b) {
    int g;
    for (g = b - 1; g >= 0; g--) {
        cout << " " << a[g];
    }
}

void print(int a[], int b) {
    int r;
    for (r = 0; r < b; r++) {
        cout << " " << a[r];
    }
}

int main() {
    int a[10] = {1, 2, 3, 4, 5, 6, 7, 9, 8, 6};
    int b = (sizeof(a) / sizeof(a[0]));
    int i;
    reverse(a, b);
    cout << endl;
    print(a, b);
    cout << endl;
    init(a, b);
}




